﻿using ServiceCore.Entity.Model;

namespace ServiceCore.Entity
{
    public class JwtUserInfo
    {
        public JwtUserInfo() { }
        public JwtUserInfo(UserInfo user) 
        { 
            this.Id = user.Id;
            this.UserName = user.UserName;
            this.Account = user.Account;
            this.IsAdmin = user.IsAdmin;
            this.IsUsed = user.IsUsed;
        }

        public System.Int64 Id { get; set; }

        /// <summary>
        /// 账号
        /// </summary>
        public System.String Account { get; set; }

        /// <summary>
        /// 用户姓名
        /// </summary>
        public System.String UserName { get; set; } = "";


        /// <summary>
        /// 是否管理员(1是0否)
        /// </summary>
        public System.Int32 IsAdmin { get; set; } = 0;

        // <
        // >
        /// 是否启用(1是0否)
        /// </summary>
        public System.Int32? IsUsed { get; set; }


        public string RefreshToken { get; set; }
    }
}
